(* Content-type: application/vnd.wolfram.mathematica *)

(*** Wolfram Notebook File ***)
(* http://www.wolfram.com/nb *)

(* CreatedBy='Mathematica 10.4' *)

(*CacheID: 234*)
(* Internal cache information:
NotebookFileLineBreakTest
NotebookFileLineBreakTest
NotebookDataPosition[       158,          7]
NotebookDataLength[     50963,       1320]
NotebookOptionsPosition[     47468,       1202]
NotebookOutlinePosition[     47830,       1218]
CellTagsIndexPosition[     47787,       1215]
WindowFrame->Normal*)

(* Beginning of Notebook Content *)
Notebook[{

Cell[CellGroupData[{
Cell["Steady State Computations", "Title",
 CellChangeTimes->{{3.7056620953690753`*^9, 3.7056620994654846`*^9}, {
  3.705663623100833*^9, 3.705663626477171*^9}}],

Cell["\<\
de la Croix, Doepke, and Mokyr: \[OpenCurlyDoubleQuote]Clans, Guilds, and \
Markets: Apprenticeship Institutions and Growth in the Pre-Industrial Economy\
\[CloseCurlyDoubleQuote]

Steady-state computations for Tables I and II\
\>", "Subsubtitle",
 CellChangeTimes->{{3.705663636477171*^9, 3.705663669791502*^9}, {
  3.705663700464569*^9, 3.705663713088831*^9}}],

Cell[CellGroupData[{

Cell["Functional form for cost of training apprentices", "Subsubsection",
 CellChangeTimes->{{3.6781844544951196`*^9, 3.678184461457057*^9}, {
  3.680849093425436*^9, 3.680849096317628*^9}, {3.69590618781328*^9, 
  3.6959061894904637`*^9}, {3.7056637194894714`*^9, 3.7056637240969315`*^9}, {
  3.705663820101531*^9, 3.705663820581579*^9}}],

Cell[BoxData[
 RowBox[{
  RowBox[{
   RowBox[{"delta", "[", "x_", "]"}], "=", 
   RowBox[{
    FractionBox["\[Delta]", "2"], " ", 
    SuperscriptBox["x", "2"]}]}], ";"}]], "Input",
 CellChangeTimes->{{3.6781813119088836`*^9, 3.6781813136610007`*^9}, {
  3.678181501802273*^9, 3.6781815156592083`*^9}, {3.678185330649723*^9, 
  3.6781853329903755`*^9}}]
}, Open  ]],

Cell[CellGroupData[{

Cell["Steady states definitions", "Subsubsection",
 CellChangeTimes->{{3.6781844544951196`*^9, 3.678184461457057*^9}, {
  3.680849093425436*^9, 3.680849096317628*^9}, {3.7056638224057617`*^9, 
  3.7056638230458255`*^9}}],

Cell["\<\
each procedure gives as result : number of masters, growth of tfp, growth of \
population, marginal cost, income per person\
\>", "Text",
 CellChangeTimes->{{3.6961652870964804`*^9, 3.696165296052868*^9}, {
   3.6961653325410604`*^9, 3.6961653552320747`*^9}, {3.6961661611570177`*^9, 
   3.696166173723031*^9}, {3.696166246047476*^9, 3.696166248453746*^9}, 
   3.7056620778483233`*^9, 3.7056637670272245`*^9}],

Cell[BoxData[
 RowBox[{
  RowBox[{"ssfamily", "[", 
   RowBox[{"param_", ",", "\[Delta]_"}], "]"}], ":=", 
  RowBox[{"Module", "[", 
   RowBox[{
    RowBox[{"{", 
     RowBox[{"m", ",", "g", ",", "n", ",", "y", ",", "a"}], "}"}], ",", 
    RowBox[{
     RowBox[{"m", "=", "1"}], ";", 
     RowBox[{"g", "=", 
      RowBox[{
       RowBox[{"m", "+", "\[Nu]"}], "/.", "param"}]}], ";", 
     "\[IndentingNewLine]", 
     RowBox[{"n", "=", 
      RowBox[{
       SuperscriptBox["g", 
        FractionBox[
         RowBox[{
          RowBox[{"(", 
           RowBox[{"1", "-", "\[Alpha]"}], ")"}], "\[Theta]"}], "\[Alpha]"]], 
       "/.", "param"}]}], ";", "\[IndentingNewLine]", 
     RowBox[{"y", "=", 
      RowBox[{
       RowBox[{
        RowBox[{"n", "/", "nb"}], "/", "s"}], "/.", "param"}]}], ";", 
     RowBox[{"a", "=", 
      RowBox[{"m", " ", "n"}]}], ";", " ", 
     RowBox[{
      RowBox[{"{", 
       RowBox[{"m", ",", 
        RowBox[{"\[Theta]", 
         RowBox[{"(", 
          RowBox[{"1", "-", "\[Alpha]"}], ")"}], 
         RowBox[{"(", 
          RowBox[{"g", "-", "1"}], ")"}]}], ",", 
        RowBox[{"n", "-", "1"}], ",", "a", ",", 
        RowBox[{
         RowBox[{"\[Delta]", " ", "a"}], "-", "\[Kappa]"}], ",", "y"}], "}"}],
       "/.", "param"}]}]}], "]"}]}]], "Input",
 CellChangeTimes->{{3.678182978150223*^9, 3.678183021904215*^9}, {
   3.67818357091078*^9, 3.678183588246016*^9}, {3.6781838179253635`*^9, 
   3.6781838227120447`*^9}, {3.678183860697336*^9, 3.678183949841482*^9}, {
   3.678184097474828*^9, 3.67818409765996*^9}, {3.6781844746640825`*^9, 
   3.6781844785938606`*^9}, {3.678185103633788*^9, 3.6781851069691563`*^9}, {
   3.680849071369405*^9, 3.680849078853876*^9}, {3.695906644469264*^9, 
   3.695906647030072*^9}, 3.6959958798932676`*^9, {3.696166176129304*^9, 
   3.6961662109151473`*^9}, {3.6961662420630207`*^9, 3.696166242438013*^9}, {
   3.6965910069694185`*^9, 3.6965910077386103`*^9}, 3.6965911622966156`*^9, 
   3.6965931150658627`*^9}],

Cell[BoxData[
 RowBox[{
  RowBox[{"ssclan", "[", 
   RowBox[{"param_", ",", "\[Delta]_"}], "]"}], ":=", 
  RowBox[{"Module", "[", 
   RowBox[{
    RowBox[{"{", 
     RowBox[{"m", ",", "g", ",", "n", ",", "y", ",", "a"}], "}"}], ",", 
    RowBox[{
     RowBox[{"g", "=", 
      RowBox[{"g", "/.", 
       RowBox[{"FindRoot", "[", 
        RowBox[{
         RowBox[{
          RowBox[{"g", "-", "1", "-", 
           FractionBox[
            RowBox[{"\[Nu]", " ", 
             SuperscriptBox["g", 
              RowBox[{
               FractionBox[
                RowBox[{
                 RowBox[{"(", 
                  RowBox[{"1", "-", "\[Alpha]"}], ")"}], "\[Theta]"}], 
                "\[Alpha]"], "o"}]]}], 
            RowBox[{"g", "-", "\[Nu]"}]]}], "/.", "param"}], ",", 
         RowBox[{"{", 
          RowBox[{"g", ",", "1.3"}], "}"}]}], "]"}]}]}], ";", 
     "\[IndentingNewLine]", 
     RowBox[{"n", "=", 
      RowBox[{
       SuperscriptBox["g", 
        FractionBox[
         RowBox[{
          RowBox[{"(", 
           RowBox[{"1", "-", "\[Alpha]"}], ")"}], "\[Theta]"}], "\[Alpha]"]], 
       "/.", "param"}]}], ";", "\[IndentingNewLine]", 
     RowBox[{"y", "=", 
      RowBox[{
       RowBox[{
        RowBox[{"n", "/", "nb"}], "/", "s"}], "/.", "param"}]}], ";", 
     "\[IndentingNewLine]", 
     RowBox[{"m", "=", 
      RowBox[{
       SuperscriptBox["n", "o"], "/.", "param"}]}], ";", " ", 
     RowBox[{"a", "=", 
      RowBox[{"m", " ", "n"}]}], ";", 
     RowBox[{
      RowBox[{"{", 
       RowBox[{"m", ",", 
        RowBox[{"\[Theta]", 
         RowBox[{"(", 
          RowBox[{"1", "-", "\[Alpha]"}], ")"}], 
         RowBox[{"(", 
          RowBox[{"g", "-", "1"}], ")"}]}], ",", 
        RowBox[{"n", "-", "1"}], ",", "a", ",", 
        RowBox[{
         RowBox[{"\[Delta]", " ", "a"}], "-", "\[Kappa]"}], ",", "y"}], "}"}],
       "/.", "param"}]}]}], "]"}]}]], "Input",
 CellChangeTimes->{{3.678183802737633*^9, 3.678183810481105*^9}, {
   3.6781839379744787`*^9, 3.6781840558978453`*^9}, {3.6781841004119015`*^9, 
   3.6781841012975297`*^9}, {3.6781841342123475`*^9, 3.678184134448517*^9}, {
   3.678184205980135*^9, 3.678184250433305*^9}, {3.6781842861546483`*^9, 
   3.6781842890226793`*^9}, 3.6781844853246155`*^9, {3.6781851169711947`*^9, 
   3.6781851189515934`*^9}, {3.6808490819326167`*^9, 3.680849083888774*^9}, 
   3.6959062930334067`*^9, {3.6959066382708874`*^9, 3.695906642203665*^9}, {
   3.695995850650951*^9, 3.6959958666072226`*^9}, {3.6961662232625*^9, 
   3.6961662615006742`*^9}, {3.6965910102386303`*^9, 3.6965910125667276`*^9}, 
   3.696591159702901*^9, 3.696593113327757*^9}],

Cell[BoxData[
 RowBox[{
  RowBox[{"ssmarket", "[", 
   RowBox[{"param_", ",", "\[Delta]_"}], "]"}], ":=", 
  RowBox[{"Module", "[", 
   RowBox[{
    RowBox[{"{", 
     RowBox[{"m", ",", "g", ",", "n", ",", "y", ",", "a"}], "}"}], ",", 
    RowBox[{
     RowBox[{"sol", "=", 
      RowBox[{"FindRoot", "[", 
       RowBox[{
        RowBox[{
         RowBox[{
          SuperscriptBox["g", 
           FractionBox[
            RowBox[{
             RowBox[{"(", 
              RowBox[{"1", "-", "\[Alpha]"}], ")"}], "\[Theta]"}], 
            "\[Alpha]"]], "-", 
          RowBox[{"\[Kappa]", "/", 
           RowBox[{"(", 
            RowBox[{
             RowBox[{"\[Delta]", 
              RowBox[{"(", 
               RowBox[{"g", "-", "\[Nu]"}], ")"}]}], "-", 
             RowBox[{"\[Gamma]", " ", "\[Theta]", " ", 
              RowBox[{
               RowBox[{"(", 
                RowBox[{"1", "-", "\[Alpha]"}], ")"}], " ", "/", 
               RowBox[{"(", 
                RowBox[{"nb", " ", "s", " ", "g"}], ")"}]}]}]}], ")"}]}]}], "/.",
          "param"}], ",", 
        RowBox[{"{", 
         RowBox[{"g", ",", "1", ",", "1.2"}], "}"}]}], "]"}]}], ";", " ", 
     "\[IndentingNewLine]", 
     RowBox[{"n", "=", 
      RowBox[{
       SuperscriptBox["g", 
        FractionBox[
         RowBox[{
          RowBox[{"(", 
           RowBox[{"1", "-", "\[Alpha]"}], ")"}], "\[Theta]"}], "\[Alpha]"]], 
       "/.", "param"}]}], ";", "\[IndentingNewLine]", 
     RowBox[{"y", "=", 
      RowBox[{
       RowBox[{
        RowBox[{"n", "/", "nb"}], "/", "s"}], "/.", "param"}]}], ";", 
     "\[IndentingNewLine]", 
     RowBox[{"m", "=", 
      RowBox[{
       RowBox[{"g", "-", "\[Nu]"}], "/.", "param"}]}], ";", 
     RowBox[{"a", "=", 
      RowBox[{"m", " ", "n"}]}], ";", 
     RowBox[{
      RowBox[{"{", 
       RowBox[{"m", ",", 
        RowBox[{"\[Theta]", 
         RowBox[{"(", 
          RowBox[{"1", "-", "\[Alpha]"}], ")"}], 
         RowBox[{"(", 
          RowBox[{"g", "-", "1"}], ")"}]}], ",", 
        RowBox[{"n", "-", "1"}], ",", "a", ",", 
        RowBox[{
         RowBox[{"\[Delta]", " ", "a"}], "-", "\[Kappa]"}], ",", "y"}], "}"}],
       "/.", 
      RowBox[{"Join", "[", 
       RowBox[{"param", ",", "sol"}], "]"}]}]}]}], "]"}]}]], "Input",
 CellChangeTimes->{{3.678185714388345*^9, 3.678185782121599*^9}, 
   3.678185816147631*^9, {3.67818599792303*^9, 3.6781860042552366`*^9}, {
   3.6781860619276257`*^9, 3.6781860960757475`*^9}, {3.678186325356409*^9, 
   3.6781863447299657`*^9}, {3.6808490860369163`*^9, 3.6808490865809526`*^9}, 
   3.6959062836537857`*^9, {3.6959066314200525`*^9, 3.6959066353998613`*^9}, 
   3.6959958476678452`*^9, {3.696166226762517*^9, 3.6961662649694605`*^9}, {
   3.69659101464489*^9, 3.696591015410494*^9}}],

Cell[BoxData[
 RowBox[{
  RowBox[{"ssguild", "[", 
   RowBox[{"param_", ",", "\[Delta]_"}], "]"}], ":=", 
  RowBox[{"Module", "[", 
   RowBox[{
    RowBox[{"{", 
     RowBox[{"m", ",", "g", ",", "n", ",", "y", ",", "a"}], "}"}], ",", 
    "\[IndentingNewLine]", 
    RowBox[{
     RowBox[{
      RowBox[{"\[CapitalOmega]", "[", "x_", "]"}], "=", 
      RowBox[{
       FractionBox[
        RowBox[{"1", "-", "\[Lambda]", "+", 
         RowBox[{
          RowBox[{"(", 
           RowBox[{"\[Lambda]", "-", "\[Theta]"}], ")"}], "x"}], "-", 
         FractionBox[
          RowBox[{
           RowBox[{"(", 
            RowBox[{"\[Gamma]", "-", "\[Theta]"}], ")"}], "x"}], 
          RowBox[{
           RowBox[{
            RowBox[{"(", 
             RowBox[{"\[Gamma]", "-", "\[Theta]"}], ")"}], "x"}], "+", 
           RowBox[{"\[Gamma]", " ", "\[Nu]"}]}]]}], 
        RowBox[{"1", "-", "\[Lambda]", "+", 
         RowBox[{
          RowBox[{"(", 
           RowBox[{"\[Lambda]", "-", "\[Theta]"}], ")"}], "x"}], "-", 
         RowBox[{"\[Lambda]", 
          FractionBox[
           RowBox[{
            RowBox[{"(", 
             RowBox[{"\[Gamma]", "-", "\[Theta]"}], ")"}], "x"}], 
           RowBox[{
            RowBox[{
             RowBox[{"(", 
              RowBox[{"\[Gamma]", "-", "\[Theta]"}], ")"}], "x"}], "+", 
            RowBox[{"\[Gamma]", " ", "\[Nu]"}]}]]}]}]], "/.", "param"}]}], 
     ";", "\[IndentingNewLine]", 
     RowBox[{"sol", "=", 
      RowBox[{"FindRoot", "[", 
       RowBox[{
        RowBox[{
         RowBox[{
          SuperscriptBox["g", 
           FractionBox[
            RowBox[{
             RowBox[{"(", 
              RowBox[{"1", "-", "\[Alpha]"}], ")"}], "\[Theta]"}], 
            "\[Alpha]"]], "-", 
          RowBox[{"\[Kappa]", "/", 
           RowBox[{"(", 
            RowBox[{
             RowBox[{"\[Delta]", 
              RowBox[{"(", 
               RowBox[{"g", "-", "\[Nu]"}], ")"}]}], "-", 
             RowBox[{
              RowBox[{"\[CapitalOmega]", "[", 
               RowBox[{"g", "-", "\[Nu]"}], "]"}], " ", "\[Gamma]", " ", 
              "\[Theta]", " ", 
              RowBox[{
               RowBox[{"(", 
                RowBox[{"1", "-", "\[Alpha]"}], ")"}], " ", "/", 
               RowBox[{"(", 
                RowBox[{"nb", " ", "s", " ", "g"}], ")"}]}]}]}], ")"}]}]}], "/.",
          "param"}], ",", 
        RowBox[{"{", 
         RowBox[{"g", ",", "1", ",", "1.2"}], "}"}]}], "]"}]}], ";", " ", 
     "\[IndentingNewLine]", 
     RowBox[{"n", "=", 
      RowBox[{
       SuperscriptBox["g", 
        FractionBox[
         RowBox[{
          RowBox[{"(", 
           RowBox[{"1", "-", "\[Alpha]"}], ")"}], "\[Theta]"}], "\[Alpha]"]], 
       "/.", "param"}]}], ";", "\[IndentingNewLine]", 
     RowBox[{"y", "=", 
      RowBox[{
       RowBox[{
        RowBox[{"n", "/", "nb"}], "/", "s"}], "/.", "param"}]}], ";", 
     "\[IndentingNewLine]", 
     RowBox[{"m", "=", 
      RowBox[{
       RowBox[{"g", "-", "\[Nu]"}], "/.", "param"}]}], ";", 
     RowBox[{"a", "=", 
      RowBox[{"m", " ", "n"}]}], ";", 
     RowBox[{
      RowBox[{"{", 
       RowBox[{"m", ",", 
        RowBox[{"\[Theta]", 
         RowBox[{"(", 
          RowBox[{"1", "-", "\[Alpha]"}], ")"}], 
         RowBox[{"(", 
          RowBox[{"g", "-", "1"}], ")"}]}], ",", 
        RowBox[{"n", "-", "1"}], ",", "a", ",", 
        RowBox[{
         RowBox[{"\[Delta]", " ", "a"}], "-", "\[Kappa]"}], ",", "y"}], "}"}],
       "/.", 
      RowBox[{"Join", "[", 
       RowBox[{"param", ",", "sol"}], "]"}]}]}]}], "]"}]}]], "Input",
 CellChangeTimes->{{3.678186508215337*^9, 3.6781865104038954`*^9}, {
   3.678186553582491*^9, 3.6781865659332423`*^9}, {3.6781866666890554`*^9, 
   3.678186787562196*^9}, {3.6808490893091335`*^9, 3.6808490898931723`*^9}, {
   3.695905834330595*^9, 3.695905836907419*^9}, {3.6959062215100513`*^9, 
   3.695906231949421*^9}, {3.69590630192068*^9, 3.695906318119111*^9}, {
   3.6959066579647894`*^9, 3.695906658407102*^9}, {3.695995826714054*^9, 
   3.695995839440035*^9}, {3.6961662301532273`*^9, 3.6961662330750723`*^9}, 
   3.6961662679382296`*^9, {3.6965910185199313`*^9, 3.696591019254304*^9}, {
   3.6965913643673024`*^9, 3.69659138382455*^9}, {3.6965916334448986`*^9, 
   3.6965916872998614`*^9}, 3.6965922446845264`*^9, 3.6965928948834286`*^9}]
}, Open  ]],

Cell[CellGroupData[{

Cell["Elasticities", "Subsubsection",
 CellChangeTimes->{{3.67818070742153*^9, 3.678180715430024*^9}, {
  3.696165405407784*^9, 3.6961654070171723`*^9}}],

Cell[BoxData[
 RowBox[{
  RowBox[{"\[Alpha]", "=", 
   RowBox[{"1", "/", "3"}]}], ";", 
  RowBox[{"\[Theta]", "=", ".5"}], ";"}]], "Input",
 CellChangeTimes->{{3.696165926269946*^9, 3.6961659312543645`*^9}, {
  3.6961661126803293`*^9, 3.6961661212897315`*^9}}]
}, Open  ]],

Cell[CellGroupData[{

Cell["Calibration of efficiency of new ideas", "Subsubsection",
 CellChangeTimes->{{3.67818070742153*^9, 3.678180715430024*^9}, {
  3.696165405407784*^9, 3.6961654070171723`*^9}, {3.69616594258603*^9, 
  3.696165943007854*^9}, {3.705663801956717*^9, 3.7056638096214833`*^9}}],

Cell["\<\
One period equal 25 years
Table 7.1 of Clark : pop increases from 7 (10000 BCE) to 300 (1000 \
CE).(300/7)^(1/440) = 1.0086
Population growth is 0.86 percent per generation\
\>", "Text",
 CellChangeTimes->{{3.678184365233751*^9, 3.6781843789908733`*^9}, {
  3.6781844227868648`*^9, 3.6781844287590976`*^9}, {3.705663854151936*^9, 
  3.7056638968092012`*^9}}],

Cell[CellGroupData[{

Cell[BoxData[
 RowBox[{"nucal", "=", 
  RowBox[{
   RowBox[{"1.0086", "^", 
    RowBox[{"(", 
     RowBox[{"\[Alpha]", "/", 
      RowBox[{"(", 
       RowBox[{
        RowBox[{"(", 
         RowBox[{"1", "-", "\[Alpha]"}], ")"}], "\[Theta]"}], ")"}]}], 
     ")"}]}], "-", "1"}]}]], "Input",
 CellChangeTimes->{{3.678184365233751*^9, 3.6781844149413304`*^9}, 
   3.695905969818576*^9, 3.6959066091106343`*^9, 3.6959066639119935`*^9, {
   3.6959066981111565`*^9, 3.6959066987455835`*^9}, {3.6959087285008335`*^9, 
   3.6959087375161963`*^9}, 3.695908818200779*^9, 3.695909188171733*^9, 
   3.695909224381277*^9, 3.695909413907733*^9, 3.695910964341675*^9, {
   3.6959966885267677`*^9, 3.695996690183059*^9}, 3.6961659475703897`*^9, {
   3.6961661146802893`*^9, 3.6961661254498763`*^9}}],

Cell[BoxData["0.008599999999999941`"], "Output",
 CellChangeTimes->{{3.6781844111616383`*^9, 3.678184415394639*^9}, 
   3.6781851108388777`*^9, 3.6785147770147448`*^9, 3.6785160019784985`*^9, 
   3.6785160561069756`*^9, 3.678516390875774*^9, 3.6785179924405527`*^9, 
   3.6785181939941254`*^9, {3.678600245105013*^9, 3.678600313060624*^9}, 
   3.6786008297419004`*^9, 3.678601033058968*^9, {3.678602573231326*^9, 
   3.678602660952924*^9}, 3.678602806535057*^9, 3.680784231855213*^9, 
   3.680784392449737*^9, 3.680786492455242*^9, 3.68078656925583*^9, 
   3.680786653665156*^9, 3.680786804824794*^9, 3.680788618898245*^9, 
   3.680849180185584*^9, 3.68085644960725*^9, 3.695905903954055*^9, 
   3.695905970531052*^9, 3.6959061976482077`*^9, 3.695906610107308*^9, 
   3.6959066643893223`*^9, 3.6959066994240694`*^9, 3.69590717290773*^9, {
   3.695908729869785*^9, 3.695908737912449*^9}, {3.6959087814749517`*^9, 
   3.6959088188702536`*^9}, 3.6959089511659093`*^9, 3.6959091896037135`*^9, 
   3.6959092249766846`*^9, 3.695909415474826*^9, 3.6959109770906734`*^9, {
   3.6959953904483156`*^9, 3.695995411294031*^9}, 3.69599589644495*^9, 
   3.6959966914486527`*^9, 3.6960944628844905`*^9, 3.696096915141824*^9, 
   3.696097009606515*^9, 3.696097216523733*^9, 3.6960978777763786`*^9, {
   3.6961014321597424`*^9, 3.6961014434286957`*^9}, 3.696166086336295*^9, 
   3.696166127637337*^9, 3.6961663656855893`*^9, 3.6965911128355026`*^9, 
   3.696591176176197*^9, 3.6965922971636024`*^9, 3.6965946609666457`*^9, 
   3.696594858344669*^9}]
}, Open  ]]
}, Open  ]],

Cell[CellGroupData[{

Cell["Summary of parameter choice", "Subsubsection",
 CellChangeTimes->{{3.67818070742153*^9, 3.678180715430024*^9}, {
  3.696165405407784*^9, 3.6961654070171723`*^9}, {3.69616594258603*^9, 
  3.696165943007854*^9}, {3.705663801956717*^9, 3.7056638096214833`*^9}, {
  3.705663918090329*^9, 3.705663924025923*^9}}],

Cell[BoxData[{
 RowBox[{
  RowBox[{"parambase", "=", 
   RowBox[{"{", 
    RowBox[{
     RowBox[{"\[Gamma]", "\[Rule]", ".1"}], ",", 
     RowBox[{"nb", "\[Rule]", "2"}], ",", 
     RowBox[{"s", "\[Rule]", "7.5"}], ",", 
     RowBox[{"o", "\[Rule]", "6"}], ",", 
     RowBox[{"\[Kappa]", "\[Rule]", ".02"}], ",", 
     RowBox[{"\[Lambda]", "\[Rule]", "1.3"}]}], "}"}]}], 
  ";"}], "\[IndentingNewLine]", 
 RowBox[{
  RowBox[{"param", "=", 
   RowBox[{"Join", "[", 
    RowBox[{"parambase", ",", 
     RowBox[{"{", 
      RowBox[{"\[Nu]", "\[Rule]", "nucal"}], "}"}]}], "]"}]}], 
  ";"}]}], "Input",
 CellChangeTimes->{{3.678180606730006*^9, 3.678180700847616*^9}, {
   3.6781808054778957`*^9, 3.678180825876747*^9}, {3.678181318425311*^9, 
   3.678181319837432*^9}, {3.678181920640334*^9, 3.6781819214284143`*^9}, {
   3.67818304924753*^9, 3.6781830529241285`*^9}, 3.6781836166019535`*^9, {
   3.678184447514203*^9, 3.678184449181376*^9}, {3.6781848157769413`*^9, 
   3.6781848171799583`*^9}, 3.6781853035737143`*^9, {3.6781862840669994`*^9, 
   3.6781862846023774`*^9}, {3.6808490073116746`*^9, 3.680849022499441*^9}, 
   3.69590597489714*^9, 3.6959066145004096`*^9, 3.6959066679818726`*^9, {
   3.695906702915548*^9, 3.695906703667079*^9}, {3.6959067718512106`*^9, 
   3.6959068098967714`*^9}, {3.6959068730923567`*^9, 3.695906902553179*^9}, {
   3.6959087444580975`*^9, 3.69590874807465*^9}, 3.695908779062278*^9, 
   3.6959088219514275`*^9, {3.6959088991569552`*^9, 3.6959089054853945`*^9}, {
   3.695909086026537*^9, 3.6959091008300133`*^9}, 3.695909193874758*^9, {
   3.6959092308838835`*^9, 3.695909288189308*^9}, {3.695909331212358*^9, 
   3.695909360018694*^9}, {3.695909419525699*^9, 3.69590943702205*^9}, {
   3.6959109665512624`*^9, 3.6959109960300713`*^9}, {3.695911281365367*^9, 
   3.6959113174350243`*^9}, {3.6959967158744397`*^9, 3.6959967162962627`*^9}, 
   3.695996780310989*^9, {3.6959971042468514`*^9, 3.6959971134188585`*^9}, {
   3.6959971845288086`*^9, 3.695997198591455*^9}, {3.696096939451013*^9, 
   3.696096983077817*^9}, {3.696097363298562*^9, 3.696097388321215*^9}, {
   3.696097459024122*^9, 3.696097460642266*^9}, {3.6961008210191207`*^9, 
   3.696100824685709*^9}, {3.6961009720223217`*^9, 3.696100991891348*^9}, {
   3.696165954820507*^9, 3.69616602277838*^9}, {3.6965910346490355`*^9, 
   3.6965910719530153`*^9}, {3.696593154070135*^9, 3.6965931579329753`*^9}}]
}, Open  ]],

Cell[CellGroupData[{

Cell["Finding the delta to equalize m across clans and guilds", \
"Subsubsection",
 CellChangeTimes->{{3.696593140194982*^9, 3.696593146163788*^9}, 
   3.705663927290249*^9}],

Cell[CellGroupData[{

Cell[BoxData[{
 RowBox[{
  RowBox[{"delta0", "=", ".015"}], ";"}], "\[IndentingNewLine]", 
 RowBox[{"Do", "[", 
  RowBox[{
   RowBox[{
    RowBox[{"delta1", "=", 
     RowBox[{"delta0", " ", "+", 
      RowBox[{
       RowBox[{"(", 
        RowBox[{
         RowBox[{"-", 
          RowBox[{
           RowBox[{"ssclan", "[", 
            RowBox[{"param", ",", "delta0"}], "]"}], "[", 
           RowBox[{"[", "1", "]"}], "]"}]}], "+", 
         RowBox[{
          RowBox[{"ssguild", "[", 
           RowBox[{"param", ",", "delta0"}], "]"}], "[", 
          RowBox[{"[", "1", "]"}], "]"}]}], ")"}], "/", "100"}]}]}], ";", 
    "\[IndentingNewLine]", 
    RowBox[{"delta0", "=", "delta1"}]}], ",", 
   RowBox[{"{", 
    RowBox[{"i", ",", "1", ",", "1000"}], "}"}]}], 
  "]"}], "\[IndentingNewLine]", 
 RowBox[{"deltabase", "=", "delta0"}]}], "Input",
 CellChangeTimes->{{3.696591510890611*^9, 3.696591527535265*^9}, {
   3.6965923720349092`*^9, 3.69659243746692*^9}, {3.696592502763336*^9, 
   3.6965925141696835`*^9}, {3.69659273635124*^9, 3.696592808851305*^9}, 
   3.6965928490314426`*^9, {3.696593014062559*^9, 3.6965930724905367`*^9}, {
   3.696593122675351*^9, 3.6965931238628616`*^9}, 3.6965948428567905`*^9}],

Cell[BoxData["0.01899380659646873`"], "Output",
 CellChangeTimes->{{3.6965930662260227`*^9, 3.6965930732609296`*^9}, 
   3.696594661076007*^9, 3.6965948598915434`*^9}]
}, Open  ]]
}, Open  ]],

Cell[CellGroupData[{

Cell["\<\
Steady states computation - lower bound on guild - TABLE I OF PAPER\
\>", "Subsubsection",
 CellChangeTimes->{{3.6808491103754396`*^9, 3.6808491222948294`*^9}, {
   3.6961663775092745`*^9, 3.6961663794486437`*^9}, {3.6961664297561054`*^9, 
   3.696166437157358*^9}, {3.7054260120433044`*^9, 3.7054260162972584`*^9}, 
   3.7056639336268826`*^9}],

Cell[CellGroupData[{

Cell[BoxData[{
 RowBox[{"ssfamily", "[", 
  RowBox[{"param", ",", "deltabase"}], "]"}], "\[IndentingNewLine]", 
 RowBox[{"ssclan", "[", 
  RowBox[{"param", ",", "deltabase"}], "]"}], "\[IndentingNewLine]", 
 RowBox[{"ssguild", "[", 
  RowBox[{"param", ",", "deltabase"}], "]"}], "\[IndentingNewLine]", 
 RowBox[{"ssmarket", "[", 
  RowBox[{"param", ",", "deltabase"}], "]"}]}], "Input",
 CellChangeTimes->{{3.680849124590951*^9, 3.6808491526992044`*^9}, {
   3.6959059293109555`*^9, 3.6959059340122786`*^9}, {3.695911349468638*^9, 
   3.695911374251131*^9}, {3.6959114082141056`*^9, 3.6959114089176025`*^9}, {
   3.6959967244872274`*^9, 3.6959967380029736`*^9}, {3.6959971215751762`*^9, 
   3.695997125559589*^9}, {3.6960944411656017`*^9, 3.696094453946931*^9}, {
   3.696096986485222*^9, 3.696096989202113*^9}, {3.69609707344761*^9, 
   3.696097118998765*^9}, {3.6960973374473295`*^9, 3.6960973587563715`*^9}, {
   3.6960974622463975`*^9, 3.696097495013611*^9}, 3.6960978051088867`*^9, {
   3.6960978638785963`*^9, 3.6960979327392054`*^9}, {3.6961008406930094`*^9, 
   3.696100955518672*^9}, {3.6961660627547426`*^9, 3.6961660795673857`*^9}, {
   3.6965930834329295`*^9, 3.6965931042339315`*^9}}],

Cell[BoxData[
 RowBox[{"{", 
  RowBox[{
  "1", ",", "0.0028666666666666467`", ",", "0.008599999999999941`", ",", 
   "1.0086`", ",", 
   RowBox[{"-", "0.0008428466668016395`"}], ",", "0.06724`"}], 
  "}"}]], "Output",
 CellChangeTimes->{
  3.696094462915742*^9, {3.696096919270754*^9, 3.6960969680231705`*^9}, 
   3.6960970096445436`*^9, {3.6960970742411556`*^9, 3.6960970932355633`*^9}, 
   3.6960971233177853`*^9, 3.696097216544734*^9, {3.696097325457837*^9, 
   3.6960973690706224`*^9}, {3.6960974665624437`*^9, 3.6960974955689864`*^9}, 
   3.6960978073224335`*^9, {3.6960978778044124`*^9, 3.696097935555166*^9}, {
   3.6961008286535234`*^9, 3.696100956667471*^9}, 3.696101340734172*^9, {
   3.6961014343352957`*^9, 3.6961014434537134`*^9}, 3.6961660863519206`*^9, 
   3.696166130496735*^9, 3.6961663813319445`*^9, 3.696593093124402*^9, 
   3.69659466109163*^9, 3.696594859985302*^9}],

Cell[BoxData[
 RowBox[{"{", 
  RowBox[{
  "1.0556984965702794`", ",", "0.0030248997723124242`", ",", 
   "0.009074699316937274`", ",", "1.0652786429959973`", ",", 
   "0.0002336965164146318`", ",", "0.06727164662112915`"}], "}"}]], "Output",
 CellChangeTimes->{
  3.696094462915742*^9, {3.696096919270754*^9, 3.6960969680231705`*^9}, 
   3.6960970096445436`*^9, {3.6960970742411556`*^9, 3.6960970932355633`*^9}, 
   3.6960971233177853`*^9, 3.696097216544734*^9, {3.696097325457837*^9, 
   3.6960973690706224`*^9}, {3.6960974665624437`*^9, 3.6960974955689864`*^9}, 
   3.6960978073224335`*^9, {3.6960978778044124`*^9, 3.696097935555166*^9}, {
   3.6961008286535234`*^9, 3.696100956667471*^9}, 3.696101340734172*^9, {
   3.6961014343352957`*^9, 3.6961014434537134`*^9}, 3.6961660863519206`*^9, 
   3.696166130496735*^9, 3.6961663813319445`*^9, 3.696593093124402*^9, 
   3.69659466109163*^9, 3.696594859985302*^9}],

Cell[BoxData[
 RowBox[{"{", 
  RowBox[{
  "1.0556984965702794`", ",", "0.0214328321900931`", ",", 
   "0.0642984965702793`", ",", "1.1235783227312526`", ",", 
   "0.0013410293579421383`", ",", "0.07095323310468529`"}], "}"}]], "Output",
 CellChangeTimes->{
  3.696094462915742*^9, {3.696096919270754*^9, 3.6960969680231705`*^9}, 
   3.6960970096445436`*^9, {3.6960970742411556`*^9, 3.6960970932355633`*^9}, 
   3.6960971233177853`*^9, 3.696097216544734*^9, {3.696097325457837*^9, 
   3.6960973690706224`*^9}, {3.6960974665624437`*^9, 3.6960974955689864`*^9}, 
   3.6960978073224335`*^9, {3.6960978778044124`*^9, 3.696097935555166*^9}, {
   3.6961008286535234`*^9, 3.696100956667471*^9}, 3.696101340734172*^9, {
   3.6961014343352957`*^9, 3.6961014434537134`*^9}, 3.6961660863519206`*^9, 
   3.696166130496735*^9, 3.6961663813319445`*^9, 3.696593093124402*^9, 
   3.69659466109163*^9, 3.6965948600009146`*^9}],

Cell[BoxData[
 RowBox[{"{", 
  RowBox[{
  "1.077360994689378`", ",", "0.028653664896459336`", ",", 
   "0.08596099468937801`", ",", "1.1699720174324146`", ",", 
   "0.0022222222223916253`", ",", "0.07239739964595854`"}], "}"}]], "Output",
 CellChangeTimes->{
  3.696094462915742*^9, {3.696096919270754*^9, 3.6960969680231705`*^9}, 
   3.6960970096445436`*^9, {3.6960970742411556`*^9, 3.6960970932355633`*^9}, 
   3.6960971233177853`*^9, 3.696097216544734*^9, {3.696097325457837*^9, 
   3.6960973690706224`*^9}, {3.6960974665624437`*^9, 3.6960974955689864`*^9}, 
   3.6960978073224335`*^9, {3.6960978778044124`*^9, 3.696097935555166*^9}, {
   3.6961008286535234`*^9, 3.696100956667471*^9}, 3.696101340734172*^9, {
   3.6961014343352957`*^9, 3.6961014434537134`*^9}, 3.6961660863519206`*^9, 
   3.696166130496735*^9, 3.6961663813319445`*^9, 3.696593093124402*^9, 
   3.69659466109163*^9, 3.6965948600009146`*^9}]
}, Open  ]]
}, Open  ]],

Cell[CellGroupData[{

Cell["Finding the delta to match data for TABLE II of PAPER", "Subsubsection",
 CellChangeTimes->{{3.696593140194982*^9, 3.696593146163788*^9}, {
  3.696593183413811*^9, 3.6965931850388255`*^9}, {3.696593679155388*^9, 
  3.6965936807335544`*^9}, {3.7054260737775598`*^9, 3.705426077609632*^9}, {
  3.705663941530673*^9, 3.705663947163236*^9}}],

Cell[CellGroupData[{

Cell[BoxData[{
 RowBox[{
  RowBox[{"delta0", "=", ".015"}], ";"}], "\[IndentingNewLine]", 
 RowBox[{"Do", "[", 
  RowBox[{
   RowBox[{
    RowBox[{"delta1", "=", 
     RowBox[{"delta0", " ", "-", 
      RowBox[{
       RowBox[{"(", 
        RowBox[{
         RowBox[{
          RowBox[{"ssclan", "[", 
           RowBox[{"param", ",", "delta0"}], "]"}], "[", 
          RowBox[{"[", "2", "]"}], "]"}], "-", 
         RowBox[{
          RowBox[{
           RowBox[{"ssfamily", "[", 
            RowBox[{"param", ",", "delta0"}], "]"}], "[", 
           RowBox[{"[", "2", "]"}], "]"}], "/", "2"}], "-", 
         RowBox[{
          RowBox[{
           RowBox[{"ssguild", "[", 
            RowBox[{"param", ",", "delta0"}], "]"}], "[", 
           RowBox[{"[", "2", "]"}], "]"}], "/", "2"}], "+", ".0253"}], ")"}], 
       "/", "100"}]}]}], ";", "\[IndentingNewLine]", 
    RowBox[{"delta0", "=", "delta1"}]}], ",", 
   RowBox[{"{", 
    RowBox[{"i", ",", "1", ",", "1000"}], "}"}]}], 
  "]"}], "\[IndentingNewLine]", 
 RowBox[{"deltam1", "=", "delta0"}]}], "Input",
 CellChangeTimes->{{3.6965937395565214`*^9, 3.696593758029451*^9}, {
   3.6965938480584555`*^9, 3.6965938742965593`*^9}, 3.6965942910436835`*^9, 
   3.696594845247466*^9}],

Cell[BoxData["0.015865853885536275`"], "Output",
 CellChangeTimes->{{3.696593851214691*^9, 3.696593875878525*^9}, {
   3.696594273586661*^9, 3.6965942918248997`*^9}, 3.696594661294774*^9, 
   3.6965948611571703`*^9}]
}, Open  ]],

Cell[CellGroupData[{

Cell[BoxData[{
 RowBox[{
  RowBox[{"delta0", "=", ".015"}], ";"}], "\[IndentingNewLine]", 
 RowBox[{"Do", "[", 
  RowBox[{
   RowBox[{
    RowBox[{"delta1", "=", 
     RowBox[{"delta0", " ", "-", 
      RowBox[{
       RowBox[{"(", 
        RowBox[{
         RowBox[{
          RowBox[{"ssclan", "[", 
           RowBox[{"param", ",", "delta0"}], "]"}], "[", 
          RowBox[{"[", "2", "]"}], "]"}], "-", 
         RowBox[{
          RowBox[{"ssguild", "[", 
           RowBox[{"param", ",", "delta0"}], "]"}], "[", 
          RowBox[{"[", "2", "]"}], "]"}], "+", ".0237"}], ")"}], "/", 
       "100"}]}]}], ";", "\[IndentingNewLine]", 
    RowBox[{"delta0", "=", "delta1"}]}], ",", 
   RowBox[{"{", 
    RowBox[{"i", ",", "1", ",", "1000"}], "}"}]}], 
  "]"}], "\[IndentingNewLine]", 
 RowBox[{"deltam2", "=", "delta0"}]}], "Input",
 CellChangeTimes->{{3.6965943599653873`*^9, 3.6965943732954497`*^9}, 
   3.6965948463099747`*^9}],

Cell[BoxData["0.01842437800230719`"], "Output",
 CellChangeTimes->{3.6965943750766745`*^9, 3.6965946614354024`*^9, 
  3.696594862500932*^9}]
}, Open  ]],

Cell[CellGroupData[{

Cell[BoxData[{
 RowBox[{
  RowBox[{"delta0", "=", ".015"}], ";"}], "\[IndentingNewLine]", 
 RowBox[{"Do", "[", 
  RowBox[{
   RowBox[{
    RowBox[{"delta1", "=", 
     RowBox[{"delta0", " ", "-", 
      RowBox[{
       RowBox[{"(", 
        RowBox[{
         RowBox[{
          RowBox[{"ssclan", "[", 
           RowBox[{"param", ",", "delta0"}], "]"}], "[", 
          RowBox[{"[", "2", "]"}], "]"}], "-", 
         RowBox[{
          RowBox[{
           RowBox[{"ssfamily", "[", 
            RowBox[{"param", ",", "delta0"}], "]"}], "[", 
           RowBox[{"[", "2", "]"}], "]"}], "/", "2"}], "-", 
         RowBox[{
          RowBox[{
           RowBox[{"ssguild", "[", 
            RowBox[{"param", ",", "delta0"}], "]"}], "[", 
           RowBox[{"[", "2", "]"}], "]"}], "/", "2"}], "+", ".0484"}], ")"}], 
       "/", "100"}]}]}], ";", "\[IndentingNewLine]", 
    RowBox[{"delta0", "=", "delta1"}]}], ",", 
   RowBox[{"{", 
    RowBox[{"i", ",", "1", ",", "1000"}], "}"}]}], 
  "]"}], "\[IndentingNewLine]", 
 RowBox[{"deltab1", "=", "delta0"}]}], "Input",
 CellChangeTimes->{{3.6965937395565214`*^9, 3.696593758029451*^9}, {
   3.6965938480584555`*^9, 3.6965938742965593`*^9}, 3.6965942910436835`*^9, {
   3.6965945132518363`*^9, 3.696594521883659*^9}, 3.6965948478133135`*^9}],

Cell[BoxData["0.01253883606526832`"], "Output",
 CellChangeTimes->{{3.696593851214691*^9, 3.696593875878525*^9}, {
   3.696594273586661*^9, 3.6965942918248997`*^9}, 3.6965945311626835`*^9, 
   3.696594661607278*^9, 3.6965948641259456`*^9}]
}, Open  ]],

Cell[CellGroupData[{

Cell[BoxData[{
 RowBox[{
  RowBox[{"delta0", "=", ".015"}], ";"}], "\[IndentingNewLine]", 
 RowBox[{"Do", "[", 
  RowBox[{
   RowBox[{
    RowBox[{"delta1", "=", 
     RowBox[{"delta0", " ", "-", 
      RowBox[{
       RowBox[{"(", 
        RowBox[{
         RowBox[{
          RowBox[{"ssclan", "[", 
           RowBox[{"param", ",", "delta0"}], "]"}], "[", 
          RowBox[{"[", "2", "]"}], "]"}], "-", 
         RowBox[{
          RowBox[{"ssguild", "[", 
           RowBox[{"param", ",", "delta0"}], "]"}], "[", 
          RowBox[{"[", "2", "]"}], "]"}], "+", ".0741"}], ")"}], "/", 
       "100"}]}]}], ";", "\[IndentingNewLine]", 
    RowBox[{"delta0", "=", "delta1"}]}], ",", 
   RowBox[{"{", 
    RowBox[{"i", ",", "1", ",", "1000"}], "}"}]}], 
  "]"}], "\[IndentingNewLine]", 
 RowBox[{"deltab2", "=", "delta0"}]}], "Input",
 CellChangeTimes->{{3.6965943599653873`*^9, 3.6965943732954497`*^9}, {
   3.6965945149550266`*^9, 3.696594529428337*^9}, 3.696594849094576*^9}],

Cell[BoxData["0.0140480647994017`"], "Output",
 CellChangeTimes->{3.6965943750766745`*^9, 3.6965945324908247`*^9, 
  3.6965946617947617`*^9, 3.6965948661729*^9}]
}, Open  ]]
}, Open  ]],

Cell[CellGroupData[{

Cell["\<\
Steady states computation - to compute the m in TABLE II of PAPER\
\>", "Subsubsection",
 CellChangeTimes->{{3.6808491103754396`*^9, 3.6808491222948294`*^9}, {
  3.6961663775092745`*^9, 3.6961663794486437`*^9}, {3.6961664437097673`*^9, 
  3.6961664476185265`*^9}, {3.705426094437948*^9, 3.70542610231617*^9}, {
  3.7056639575482745`*^9, 3.7056639586993895`*^9}}],

Cell[CellGroupData[{

Cell[BoxData[{
 RowBox[{"ssguild", "[", 
  RowBox[{"param", ",", "deltam1"}], "]"}], "\[IndentingNewLine]", 
 RowBox[{"ssmarket", "[", 
  RowBox[{"param", ",", "deltam1"}], "]"}], "\[IndentingNewLine]", 
 RowBox[{"ssguild", "[", 
  RowBox[{"param", ",", "deltam2"}], "]"}], "\[IndentingNewLine]", 
 RowBox[{"ssmarket", "[", 
  RowBox[{"param", ",", "deltam2"}], "]"}], "\[IndentingNewLine]", 
 RowBox[{"ssguild", "[", 
  RowBox[{"param", ",", "deltab1"}], "]"}], "\[IndentingNewLine]", 
 RowBox[{"ssmarket", "[", 
  RowBox[{"param", ",", "deltab1"}], "]"}], "\[IndentingNewLine]", 
 RowBox[{"ssguild", "[", 
  RowBox[{"param", ",", "deltab2"}], "]"}], "\[IndentingNewLine]", 
 RowBox[{"ssmarket", "[", 
  RowBox[{"param", ",", "deltab2"}], "]"}]}], "Input",
 CellChangeTimes->{{3.6965938862380147`*^9, 3.696593888613063*^9}, {
  3.696594444139092*^9, 3.696594450732896*^9}, {3.6965945407604103`*^9, 
  3.6965945539323683`*^9}}],

Cell[BoxData[
 RowBox[{"{", 
  RowBox[{
  "1.1527493986338755`", ",", "0.053783132877958474`", ",", 
   "0.16134939863387543`", ",", "1.338744820879013`", ",", 
   "0.0012403297180848503`", ",", "0.07742329324225836`"}], "}"}]], "Output",
 CellChangeTimes->{
  3.696097216568761*^9, 3.696100959230274*^9, 3.6961009943570595`*^9, 
   3.696101443480732*^9, 3.696166408059803*^9, 3.6965938899567657`*^9, {
   3.696594281262293*^9, 3.6965942946061563`*^9}, 3.696594451170355*^9, 
   3.6965945547760963`*^9, 3.6965946618103867`*^9, 3.6965948662041044`*^9}],

Cell[BoxData[
 RowBox[{"{", 
  RowBox[{
  "1.1791907952514717`", ",", "0.06259693175049055`", ",", 
   "0.1877907952514717`", ",", "1.400631972444961`", ",", 
   "0.002222222222222219`", ",", "0.07918605301676478`"}], "}"}]], "Output",
 CellChangeTimes->{
  3.696097216568761*^9, 3.696100959230274*^9, 3.6961009943570595`*^9, 
   3.696101443480732*^9, 3.696166408059803*^9, 3.6965938899567657`*^9, {
   3.696594281262293*^9, 3.6965942946061563`*^9}, 3.696594451170355*^9, 
   3.6965945547760963`*^9, 3.6965946618103867`*^9, 3.6965948662041044`*^9}],

Cell[BoxData[
 RowBox[{"{", 
  RowBox[{
  "1.0715746993169377`", ",", "0.02672489977231255`", ",", 
   "0.08017469931693766`", ",", "1.157487878630311`", ",", 
   "0.0013259942089735195`", ",", "0.07201164662112917`"}], "}"}]], "Output",
 CellChangeTimes->{
  3.696097216568761*^9, 3.696100959230274*^9, 3.6961009943570595`*^9, 
   3.696101443480732*^9, 3.696166408059803*^9, 3.6965938899567657`*^9, {
   3.696594281262293*^9, 3.6965942946061563`*^9}, 3.696594451170355*^9, 
   3.6965945547760963`*^9, 3.6965946618103867`*^9, 3.6965948662041044`*^9}],

Cell[BoxData[
 RowBox[{"{", 
  RowBox[{
  "1.093948589957762`", ",", "0.034182863319253944`", ",", 
   "0.10254858995776184`", ",", "1.206131475344212`", ",", 
   "0.002222222222222219`", ",", "0.07350323933051746`"}], "}"}]], "Output",
 CellChangeTimes->{
  3.696097216568761*^9, 3.696100959230274*^9, 3.6961009943570595`*^9, 
   3.696101443480732*^9, 3.696166408059803*^9, 3.6965938899567657`*^9, {
   3.696594281262293*^9, 3.6965942946061563`*^9}, 3.696594451170355*^9, 
   3.6965945547760963`*^9, 3.6965946618103867`*^9, 3.6965948662197285`*^9}],

Cell[BoxData[
 RowBox[{"{", 
  RowBox[{
  "1.2913493986338742`", ",", "0.09998313287795804`", ",", 
   "0.29994939863387415`", ",", "1.6786888741803199`", ",", 
   "0.0010488045979368636`", ",", "0.08666329324225827`"}], "}"}]], "Output",
 CellChangeTimes->{
  3.696097216568761*^9, 3.696100959230274*^9, 3.6961009943570595`*^9, 
   3.696101443480732*^9, 3.696166408059803*^9, 3.6965938899567657`*^9, {
   3.696594281262293*^9, 3.6965942946061563`*^9}, 3.696594451170355*^9, 
   3.6965945547760963`*^9, 3.6965946618103867`*^9, 3.6965948662197285`*^9}],

Cell[BoxData[
 RowBox[{"{", 
  RowBox[{
  "1.3269738349196956`", ",", "0.11185794497323183`", ",", 
   "0.3355738349196955`", ",", "1.7722715335417927`", ",", 
   "0.0022222222222222227`", ",", "0.08903825566131303`"}], "}"}]], "Output",
 CellChangeTimes->{
  3.696097216568761*^9, 3.696100959230274*^9, 3.6961009943570595`*^9, 
   3.696101443480732*^9, 3.696166408059803*^9, 3.6965938899567657`*^9, {
   3.696594281262293*^9, 3.6965942946061563`*^9}, 3.696594451170355*^9, 
   3.6965945547760963`*^9, 3.6965946618103867`*^9, 3.6965948662197285`*^9}],

Cell[BoxData[
 RowBox[{"{", 
  RowBox[{
  "1.2227746993169373`", ",", "0.0771248997723124`", ",", 
   "0.23137469931693722`", ",", "1.505693827703752`", ",", 
   "0.0011520844596414857`", ",", "0.08209164662112915`"}], "}"}]], "Output",
 CellChangeTimes->{
  3.696097216568761*^9, 3.696100959230274*^9, 3.6961009943570595`*^9, 
   3.696101443480732*^9, 3.696166408059803*^9, 3.6965938899567657`*^9, {
   3.696594281262293*^9, 3.6965942946061563`*^9}, 3.696594451170355*^9, 
   3.6965945547760963`*^9, 3.6965946618103867`*^9, 3.6965948662197285`*^9}],

Cell[BoxData[
 RowBox[{"{", 
  RowBox[{
  "1.2534317674494662`", ",", "0.08734392248315537`", ",", 
   "0.2620317674494661`", ",", "1.581870708851558`", ",", 
   "0.0022222222222221845`", ",", "0.08413545116329774`"}], "}"}]], "Output",
 CellChangeTimes->{
  3.696097216568761*^9, 3.696100959230274*^9, 3.6961009943570595`*^9, 
   3.696101443480732*^9, 3.696166408059803*^9, 3.6965938899567657`*^9, {
   3.696594281262293*^9, 3.6965942946061563`*^9}, 3.696594451170355*^9, 
   3.6965945547760963`*^9, 3.6965946618103867`*^9, 3.696594866235354*^9}]
}, Open  ]],

Cell["\<\
predicted differences China - Europe for the periods 1 - 1000, 1000 - 1500, \
1500 - 1820\
\>", "Text",
 CellChangeTimes->{{3.69591113161849*^9, 3.695911157731459*^9}}],

Cell[CellGroupData[{

Cell[BoxData[
 RowBox[{" ", 
  RowBox[{
   RowBox[{"(", 
    RowBox[{
     RowBox[{
      RowBox[{"ssclan", "[", 
       RowBox[{"param", ",", "deltam1"}], "]"}], "[", 
      RowBox[{"[", "2", "]"}], "]"}], "-", 
     RowBox[{
      RowBox[{"ssfamily", "[", 
       RowBox[{"param", ",", "deltam1"}], "]"}], "[", 
      RowBox[{"[", "2", "]"}], "]"}]}], ")"}], "\[IndentingNewLine]", " ", 
   RowBox[{"(", 
    RowBox[{
     RowBox[{
      RowBox[{"ssclan", "[", 
       RowBox[{"param", ",", "deltam1"}], "]"}], "[", 
      RowBox[{"[", "2", "]"}], "]"}], "-", 
     RowBox[{
      RowBox[{
       RowBox[{"ssfamily", "[", 
        RowBox[{"param", ",", "deltam1"}], "]"}], "[", 
       RowBox[{"[", "2", "]"}], "]"}], "/", "2"}], "-", 
     RowBox[{
      RowBox[{
       RowBox[{"ssguild", "[", 
        RowBox[{"param", ",", "deltam1"}], "]"}], "[", 
       RowBox[{"[", "2", "]"}], "]"}], "/", "2"}]}], ")"}], 
   "\[IndentingNewLine]", " ", 
   RowBox[{"(", 
    RowBox[{
     RowBox[{
      RowBox[{"ssclan", "[", 
       RowBox[{"param", ",", "deltam1"}], "]"}], "[", 
      RowBox[{"[", "2", "]"}], "]"}], "-", 
     RowBox[{
      RowBox[{"ssguild", "[", 
       RowBox[{"param", ",", "deltam1"}], "]"}], "[", 
      RowBox[{"[", "2", "]"}], "]"}]}], ")"}]}]}]], "Input",
 CellChangeTimes->{{3.6959110258240767`*^9, 3.695911041052853*^9}, {
  3.695911114833638*^9, 3.695911120165412*^9}, {3.6959958175605927`*^9, 
  3.695995821734538*^9}, {3.6959971699036827`*^9, 3.6959971732474375`*^9}, {
  3.6965943178175983`*^9, 3.6965943361819134`*^9}}],

Cell[BoxData["0.00015823310564577753`"], "Output",
 CellChangeTimes->{{3.695911037041007*^9, 3.6959110416032276`*^9}, 
   3.6959111268621454`*^9, 3.6959111614981165`*^9, {3.6959112883423057`*^9, 
   3.695911321072565*^9}, 3.6959954226840734`*^9, 3.6959958964990053`*^9, 
   3.695996750256868*^9, 3.695996784170342*^9, 3.695997174747459*^9, 
   3.6960944629626026`*^9, 3.6960970096945868`*^9, 3.696097132019269*^9, 
   3.696097216602793*^9, {3.696097379093707*^9, 3.6960973943514853`*^9}, {
   3.6961009657298627`*^9, 3.6961009985100007`*^9}, 3.696101443512755*^9, 
   3.6965943369149065`*^9, 3.696594661966653*^9, 3.696594866235354*^9}],

Cell[BoxData[
 RowBox[{"-", "0.025300000000000135`"}]], "Output",
 CellChangeTimes->{{3.695911037041007*^9, 3.6959110416032276`*^9}, 
   3.6959111268621454`*^9, 3.6959111614981165`*^9, {3.6959112883423057`*^9, 
   3.695911321072565*^9}, 3.6959954226840734`*^9, 3.6959958964990053`*^9, 
   3.695996750256868*^9, 3.695996784170342*^9, 3.695997174747459*^9, 
   3.6960944629626026`*^9, 3.6960970096945868`*^9, 3.696097132019269*^9, 
   3.696097216602793*^9, {3.696097379093707*^9, 3.6960973943514853`*^9}, {
   3.6961009657298627`*^9, 3.6961009985100007`*^9}, 3.696101443512755*^9, 
   3.6965943369149065`*^9, 3.696594661966653*^9, 3.69659486625098*^9}],

Cell[BoxData[
 RowBox[{"-", "0.05075823310564605`"}]], "Output",
 CellChangeTimes->{{3.695911037041007*^9, 3.6959110416032276`*^9}, 
   3.6959111268621454`*^9, 3.6959111614981165`*^9, {3.6959112883423057`*^9, 
   3.695911321072565*^9}, 3.6959954226840734`*^9, 3.6959958964990053`*^9, 
   3.695996750256868*^9, 3.695996784170342*^9, 3.695997174747459*^9, 
   3.6960944629626026`*^9, 3.6960970096945868`*^9, 3.696097132019269*^9, 
   3.696097216602793*^9, {3.696097379093707*^9, 3.6960973943514853`*^9}, {
   3.6961009657298627`*^9, 3.6961009985100007`*^9}, 3.696101443512755*^9, 
   3.6965943369149065`*^9, 3.696594661966653*^9, 3.69659486625098*^9}]
}, Open  ]],

Cell[CellGroupData[{

Cell[BoxData[
 RowBox[{" ", 
  RowBox[{
   RowBox[{"(", 
    RowBox[{
     RowBox[{
      RowBox[{"ssclan", "[", 
       RowBox[{"param", ",", "deltam2"}], "]"}], "[", 
      RowBox[{"[", "2", "]"}], "]"}], "-", 
     RowBox[{
      RowBox[{"ssfamily", "[", 
       RowBox[{"param", ",", "deltam2"}], "]"}], "[", 
      RowBox[{"[", "2", "]"}], "]"}]}], ")"}], "\[IndentingNewLine]", " ", 
   RowBox[{"(", 
    RowBox[{
     RowBox[{
      RowBox[{"ssclan", "[", 
       RowBox[{"param", ",", "deltam2"}], "]"}], "[", 
      RowBox[{"[", "2", "]"}], "]"}], "-", 
     RowBox[{
      RowBox[{
       RowBox[{"ssfamily", "[", 
        RowBox[{"param", ",", "deltam2"}], "]"}], "[", 
       RowBox[{"[", "2", "]"}], "]"}], "/", "2"}], "-", 
     RowBox[{
      RowBox[{
       RowBox[{"ssguild", "[", 
        RowBox[{"param", ",", "deltam2"}], "]"}], "[", 
       RowBox[{"[", "2", "]"}], "]"}], "/", "2"}]}], ")"}], 
   "\[IndentingNewLine]", " ", 
   RowBox[{"(", 
    RowBox[{
     RowBox[{
      RowBox[{"ssclan", "[", 
       RowBox[{"param", ",", "deltam2"}], "]"}], "[", 
      RowBox[{"[", "2", "]"}], "]"}], "-", 
     RowBox[{
      RowBox[{"ssguild", "[", 
       RowBox[{"param", ",", "deltam2"}], "]"}], "[", 
      RowBox[{"[", "2", "]"}], "]"}]}], ")"}]}]}]], "Input",
 CellChangeTimes->{{3.6959110258240767`*^9, 3.695911041052853*^9}, {
  3.695911114833638*^9, 3.695911120165412*^9}, {3.6959958175605927`*^9, 
  3.695995821734538*^9}, {3.6959971699036827`*^9, 3.6959971732474375`*^9}, {
  3.6965943178175983`*^9, 3.6965943361819134`*^9}, {3.6965944627837005`*^9, 
  3.6965944758150616`*^9}}],

Cell[BoxData["0.00015823310564577753`"], "Output",
 CellChangeTimes->{3.6965944768306513`*^9, 3.6965946619822626`*^9, 
  3.696594866266592*^9}],

Cell[BoxData[
 RowBox[{"-", "0.011770883447177175`"}]], "Output",
 CellChangeTimes->{3.6965944768306513`*^9, 3.6965946619822626`*^9, 
  3.696594866266592*^9}],

Cell[BoxData[
 RowBox[{"-", "0.023700000000000127`"}]], "Output",
 CellChangeTimes->{3.6965944768306513`*^9, 3.6965946619822626`*^9, 
  3.696594866266592*^9}]
}, Open  ]],

Cell[CellGroupData[{

Cell[BoxData[
 RowBox[{" ", 
  RowBox[{
   RowBox[{"(", 
    RowBox[{
     RowBox[{
      RowBox[{"ssclan", "[", 
       RowBox[{"param", ",", "deltab1"}], "]"}], "[", 
      RowBox[{"[", "2", "]"}], "]"}], "-", 
     RowBox[{
      RowBox[{
       RowBox[{"ssfamily", "[", 
        RowBox[{"param", ",", "deltab1"}], "]"}], "[", 
       RowBox[{"[", "2", "]"}], "]"}], "/", "2"}], "-", 
     RowBox[{
      RowBox[{
       RowBox[{"ssguild", "[", 
        RowBox[{"param", ",", "deltab1"}], "]"}], "[", 
       RowBox[{"[", "2", "]"}], "]"}], "/", "2"}]}], ")"}], 
   "\[IndentingNewLine]", " ", 
   RowBox[{"(", 
    RowBox[{
     RowBox[{
      RowBox[{"ssclan", "[", 
       RowBox[{"param", ",", "deltab1"}], "]"}], "[", 
      RowBox[{"[", "2", "]"}], "]"}], "-", 
     RowBox[{
      RowBox[{"ssguild", "[", 
       RowBox[{"param", ",", "deltab1"}], "]"}], "[", 
      RowBox[{"[", "2", "]"}], "]"}]}], ")"}]}]}]], "Input",
 CellChangeTimes->{{3.696594577296152*^9, 3.696594593940335*^9}}],

Cell[BoxData[
 RowBox[{"-", "0.04839999999999992`"}]], "Output",
 CellChangeTimes->{3.696594604193457*^9, 3.696594661997889*^9, 
  3.6965948662822275`*^9}],

Cell[BoxData[
 RowBox[{"-", "0.09695823310564562`"}]], "Output",
 CellChangeTimes->{3.696594604193457*^9, 3.696594661997889*^9, 
  3.6965948662822275`*^9}]
}, Open  ]],

Cell[CellGroupData[{

Cell[BoxData[
 RowBox[{" ", 
  RowBox[{
   RowBox[{"(", 
    RowBox[{
     RowBox[{
      RowBox[{"ssclan", "[", 
       RowBox[{"param", ",", "deltab2"}], "]"}], "[", 
      RowBox[{"[", "2", "]"}], "]"}], "-", 
     RowBox[{
      RowBox[{
       RowBox[{"ssfamily", "[", 
        RowBox[{"param", ",", "deltab2"}], "]"}], "[", 
       RowBox[{"[", "2", "]"}], "]"}], "/", "2"}], "-", 
     RowBox[{
      RowBox[{
       RowBox[{"ssguild", "[", 
        RowBox[{"param", ",", "deltab2"}], "]"}], "[", 
       RowBox[{"[", "2", "]"}], "]"}], "/", "2"}]}], ")"}], 
   "\[IndentingNewLine]", " ", 
   RowBox[{"(", 
    RowBox[{
     RowBox[{
      RowBox[{"ssclan", "[", 
       RowBox[{"param", ",", "deltab2"}], "]"}], "[", 
      RowBox[{"[", "2", "]"}], "]"}], "-", 
     RowBox[{
      RowBox[{"ssguild", "[", 
       RowBox[{"param", ",", "deltab2"}], "]"}], "[", 
      RowBox[{"[", "2", "]"}], "]"}]}], ")"}]}]}]], "Input",
 CellChangeTimes->{{3.696594595768515*^9, 3.696594602818488*^9}}],

Cell[BoxData[
 RowBox[{"-", "0.036970883447177104`"}]], "Output",
 CellChangeTimes->{3.6965946061465855`*^9, 3.696594662013529*^9, 
  3.6965948662822275`*^9}],

Cell[BoxData[
 RowBox[{"-", "0.07409999999999999`"}]], "Output",
 CellChangeTimes->{3.6965946061465855`*^9, 3.696594662013529*^9, 
  3.696594866297852*^9}]
}, Open  ]]
}, Open  ]]
}, Open  ]]
},
WindowSize->{3808, 1937},
WindowMargins->{{0, Automatic}, {Automatic, 0}},
Magnification->3.,
FrontEndVersion->"10.4 for Microsoft Windows (64-bit) (April 11, 2016)",
StyleDefinitions->"Default.nb"
]
(* End of Notebook Content *)

(* Internal cache information *)
(*CellTagsOutline
CellTagsIndex->{}
*)
(*CellTagsIndex
CellTagsIndex->{}
*)
(*NotebookFileOutline
Notebook[{
Cell[CellGroupData[{
Cell[580, 22, 161, 2, 303, "Title"],
Cell[744, 26, 372, 8, 307, "Subsubtitle"],
Cell[CellGroupData[{
Cell[1141, 38, 339, 4, 115, "Subsubsection"],
Cell[1483, 44, 353, 9, 130, "Input"]
}, Open  ]],
Cell[CellGroupData[{
Cell[1873, 58, 220, 3, 115, "Subsubsection"],
Cell[2096, 63, 419, 7, 89, "Text"],
Cell[2518, 72, 1994, 49, 338, "Input"],
Cell[4515, 123, 2636, 67, 453, "Input"],
Cell[7154, 192, 2773, 74, 612, "Input"],
Cell[9930, 268, 4333, 113, 734, "Input"]
}, Open  ]],
Cell[CellGroupData[{
Cell[14300, 386, 153, 2, 115, "Subsubsection"],
Cell[14456, 390, 260, 6, 91, "Input"]
}, Open  ]],
Cell[CellGroupData[{
Cell[14753, 401, 275, 3, 115, "Subsubsection"],
Cell[15031, 406, 368, 8, 201, "Text"],
Cell[CellGroupData[{
Cell[15424, 418, 786, 17, 91, "Input"],
Cell[16213, 437, 1532, 21, 87, "Output"]
}, Open  ]]
}, Open  ]],
Cell[CellGroupData[{
Cell[17794, 464, 313, 4, 115, "Subsubsection"],
Cell[18110, 470, 2397, 42, 150, "Input"]
}, Open  ]],
Cell[CellGroupData[{
Cell[20544, 517, 174, 3, 115, "Subsubsection"],
Cell[CellGroupData[{
Cell[20743, 524, 1215, 30, 266, "Input"],
Cell[21961, 556, 167, 2, 87, "Output"]
}, Open  ]]
}, Open  ]],
Cell[CellGroupData[{
Cell[22177, 564, 354, 6, 115, "Subsubsection"],
Cell[CellGroupData[{
Cell[22556, 574, 1197, 19, 266, "Input"],
Cell[23756, 595, 887, 16, 87, "Output"],
Cell[24646, 613, 911, 15, 87, "Output"],
Cell[25560, 630, 908, 15, 87, "Output"],
Cell[26471, 647, 910, 15, 87, "Output"]
}, Open  ]]
}, Open  ]],
Cell[CellGroupData[{
Cell[27430, 668, 343, 4, 115, "Subsubsection"],
Cell[CellGroupData[{
Cell[27798, 676, 1235, 33, 498, "Input"],
Cell[29036, 711, 216, 3, 87, "Output"]
}, Open  ]],
Cell[CellGroupData[{
Cell[29289, 719, 933, 26, 266, "Input"],
Cell[30225, 747, 140, 2, 87, "Output"]
}, Open  ]],
Cell[CellGroupData[{
Cell[30402, 754, 1285, 33, 498, "Input"],
Cell[31690, 789, 239, 3, 87, "Output"]
}, Open  ]],
Cell[CellGroupData[{
Cell[31966, 797, 979, 26, 266, "Input"],
Cell[32948, 825, 161, 2, 87, "Output"]
}, Open  ]]
}, Open  ]],
Cell[CellGroupData[{
Cell[33158, 833, 372, 6, 115, "Subsubsection"],
Cell[CellGroupData[{
Cell[33555, 843, 927, 19, 498, "Input"],
Cell[34485, 864, 551, 10, 87, "Output"],
Cell[35039, 876, 548, 10, 87, "Output"],
Cell[35590, 888, 550, 10, 87, "Output"],
Cell[36143, 900, 549, 10, 87, "Output"],
Cell[36695, 912, 551, 10, 87, "Output"],
Cell[37249, 924, 550, 10, 87, "Output"],
Cell[37802, 936, 549, 10, 87, "Output"],
Cell[38354, 948, 547, 10, 87, "Output"]
}, Open  ]],
Cell[38916, 961, 178, 4, 89, "Text"],
Cell[CellGroupData[{
Cell[39119, 969, 1552, 43, 208, "Input"],
Cell[40674, 1014, 636, 8, 87, "Output"],
Cell[41313, 1024, 650, 9, 87, "Output"],
Cell[41966, 1035, 649, 9, 87, "Output"]
}, Open  ]],
Cell[CellGroupData[{
Cell[42652, 1049, 1605, 44, 208, "Input"],
Cell[44260, 1095, 143, 2, 87, "Output"],
Cell[44406, 1099, 158, 3, 87, "Output"],
Cell[44567, 1104, 158, 3, 87, "Output"]
}, Open  ]],
Cell[CellGroupData[{
Cell[44762, 1112, 997, 30, 150, "Input"],
Cell[45762, 1144, 155, 3, 87, "Output"],
Cell[45920, 1149, 155, 3, 87, "Output"]
}, Open  ]],
Cell[CellGroupData[{
Cell[46112, 1157, 997, 30, 150, "Input"],
Cell[47112, 1189, 158, 3, 87, "Output"],
Cell[47273, 1194, 155, 3, 87, "Output"]
}, Open  ]]
}, Open  ]]
}, Open  ]]
}
]
*)

